const changeKey: any = {
  SRC_todo: "采购部门",
  PRD_todo: "生产部门",
  MTD_todo: "维护部门",
  SALE_todo: "销售部门",
  QA_todo: "质量保证部门",
};

const dataKey = (data: any) => {
  let newObject: any = {};
  for (let key in data) {
    newObject[changeKey[key]] = data[key];
  }
  return newObject;
};
const dataType = (data: any) => {
  const type = Object.prototype.toString.call(data).slice(8, -1);
  return type;
};
const dataList = {
  warhousing_id: "入库成品编号",
  produce_date: "生产日期",
  finish_date: "完工日期",
  qualify: "入库合格情况",
  warehousing_QAid: "质检员编号",
  department: "责任部门",
  message: "备注",
  out_id: "出库成品编号",
  out_date: "发货日期",
  out_qualify: "出库合格情况",
  out_QAid: "质检员编号",
  matirial_id: "原料编号",
  purchase_date: "购买日期",
  matirail_Qualify: "原料合格情况",
  matriaial_QAid: "质检员编号",
};
export { changeKey, dataKey, dataType, dataList };
